#!/usr/bin/python

import bsddb as bdb
import os, sys
import urllib

            
cxn = bdb.db.DB()
dbPath = "aggregatorCache.bdb.old"
cxn.open(dbPath)
c = cxn.cursor()
(k,v) = c.first()

while k:
    print k
    fh = urllib.urlopen('http://mementoproxy.lanl.gov/aggr/timegate/%s' % k)
    fh.close()
    try:
        (k, v) = c.next()
    except:
        k = None

cxn.close()



